SetAllDigital()

Coding and general discussion relating to the compiler

Moderators: David Barker, Jerry Messina

Post Reply
IanR
Posts: 2
Joined: Wed Jan 22, 2014 10:39 am
Location: Stockholm

SetAllDigital()

Post by IanR » Wed Jan 22, 2014 1:43 pm

You can find a more up to date replacement for SetAllDigital() on the wiki page http://www.sfcompiler.co.uk/wiki/pmwiki ... tDigitalIO .

I have downloaded the new SetAllDigitial code from Wiki.

Utils.bas is a Read Only System file so it can't be modified. So how does one incorporate this update ?

BR

User avatar
David Barker
Swordfish Developer
Posts: 1214
Joined: Tue Oct 03, 2006 7:01 pm
Location: Saltburn by the Sea, UK
Contact:

Re: SetAllDigital()

Post by David Barker » Wed Jan 22, 2014 2:07 pm

Jerry has written a very good replacement for set all digital. One way to integrate this module into Swordfish is by editing "utils.bas" and make the following changes:

Code: Select all

Module Utils

Include "setdigitalio.bas" ' add this
Public Dim SetAllDigital As SetDigitalIO.SetAllDigital ' add this
and delete the SetAllDigital() sub at the bottom of the module. Alternatively, download and install the latest version of the compiler which has these changes already made. If using the non-paid for version of Swordfish, don't forget to use "SWORDFISH_SE = true" before any module includes. For example,

Code: Select all

Device = 18F46K22 

#option SWORDFISH_SE = true
Include "lcd.bas"

LCD.WriteAt(1,1,"Hello")

Post Reply