PIC Device For Swordfish Free Spedial Edition

Discuss the Integrated Development Environment (IDE)

Moderators: David Barker, Jerry Messina

Post Reply
swordfishuser
Posts: 19
Joined: Sun Apr 09, 2017 7:07 pm

PIC Device For Swordfish Free Spedial Edition

Post by swordfishuser » Sun Apr 30, 2017 12:13 am

Saw this after rereading Special Editon description.

"some newer Microchip devices have Special Function Registers (SFRs) that reside outside of access RAM. The SE version will be unable to access these SFRs by default."

Will the PIC that comes on the Firewing run fully functioning in Swordfish SE?

I think it would be informative to plod through datasheets of chips supported by Swordfish commercial edition.

Does anybody which chips on that list DO NOT have SFR''s and will run correctly with SE?
Last edited by swordfishuser on Sun Apr 30, 2017 3:45 pm, edited 1 time in total.

Jerry Messina
Swordfish Developer
Posts: 1246
Joined: Fri Jan 30, 2009 6:27 pm
Location: US

Re: PIC Device For Swordfish Free Spedial Edition

Post by Jerry Messina » Sun Apr 30, 2017 1:17 am

Will the PIC that comes on the Firewing run fully functioning in Swordfish SE?
Not directly.

If you look at the SFR memory map in that datasheet you'll see a note:

Code: Select all

Note 1: Addresses F38h through F5Fh are also used by SFRs, but are not part of the Access RAM. 
Users must always use the complete address or load the proper BSR value to access these registers.
If you look at the code in http://www.sfcompiler.co.uk/wiki/pmwiki ... tDigitalIO
there are two macros 'read_sfr()' and 'write_sfr()' that allow you to write code that'll access these registers in the SE version.
Does anybody which chips on that list DO NOT have SFR's and will run correctly with SE?
Not an entire list, but older chips tend not to. Anything not in the J or K series should probably be ok but unfortunately you'll have to check the datasheet since with pics there's no absolute rule.
The macros above should work though.

Also, keep in mind that the SE version only supports the first bank of ram so you have < 256 bytes to work with.
There's no 'fix' for that.

swordfishuser
Posts: 19
Joined: Sun Apr 09, 2017 7:07 pm

Re: PIC Device For Swordfish Free Spedial Edition

Post by swordfishuser » Sun Apr 30, 2017 3:44 pm

Jerry

Okay. So in car racing talk. 'It will run'. Which you're probably big on being in Virginia.

That is a very good answer!

I'm sold. Firewing 8 bit board we'll be okay.

Worth it just to use it in Firewing and Swordfish SE.

If it can be hacked to use with Pic Basic and Proton that's a bonus.

I just like to work a little in each language and switch back and forth.

Once again. Thank you for very sharp answer!

Post Reply