News:

Let's find out together what makes a PIC Tick!

Main Menu

I cannot use 12F510 with positron8

Started by Dyonizos, Jun 10, 2022, 08:01 AM

Previous topic - Next topic

Dyonizos

Hi,
I have a problem with positron8 with 12F510

I just write this code
  Device = 12F510     ' Choose the device to compile for

  Declare Xtal = 8     ' Inform the compiler of the speed of the microcontroller

but i got this error message trying compile.

Error [115] A.S 23 : Duplicate labe ("TRISB" or redefining symbol that cannot be redefined)


Can you help me ?

Thanks

charliem

Take a look at the PPI file for the 12f510. Open in notepad or any text editor and scroll down to SFR definitions
and comment out the TrisB definition (;TRISB=0X000A) then save. you should be able to compile.

Hope this helps.

joesaliba

Try to use TRISGPIO instead.

I am not sure what I am reading on page 34 of the datasheet, but it looks that TRISGPIO is the way to go.

Regards

Joe

Dyonizos

Quote from: charliem on Jun 10, 2022, 09:34 AMTake a look at the PPI file for the 12f510. Open in notepad or any text editor and scroll down to SFR definitions
and comment out the TrisB definition (;TRISB=0X000A) then save. you should be able to compile.

Hope this helps.


Thanks. That's works.