Liberty BASIC Community Forum
« Search Results »

Welcome Guest. Please Login or Register.
Mar 28th, 2015, 10:58am


Rules|Home|Help|Search|Recent Posts|Notification

--Liberty BASIC Resources--
Yahoo Code Repository (source must be included)
Liberty BASIC Community WikiSpace
Liberty Labs
Bay Six Software Forum
Liberty BASIC Home Page

Official Liberty BASIC Support
Liberty BASIC Programmer's Encyclopedia
Liberty BASIC 5 Handbook
Liberty BASIC on Rosetta Code

Search Results

Total results: 10


 1   Hardware Interface Coding / LB library for Arduino interface and control  on: Yesterday at 9:11pm
Started by mmiscool | Post by mmiscool
This is a new thread to facilitate the discussion and planing of an advanced library and demo code for interfacing with the arduino micro controller.

Please post only in relation to the planing and execution of creating an advanced set of functions and code for interfacing with an arduino.

To start off the discussion lets set some clear objectives for the resulting code.

Port I/O is one thing that will re required along with PWM input and output. What other features would be needed in such a library and what would the intended applications be for such a project?



 
  Reply Quote Notify of replies

 2   General Board / Moved: Team Liberty basic images showing up as broken  on: Mar 26th, 2015, 7:11pm
Started by mmiscool | Post by mmiscool
This topic has been moved to Suggestions and Discussion About This Forum by Alyce Watson.

 
  Reply Quote Notify of replies

 3   Hardware Interface Coding / Re: Arduino library for LB for pin I/O and PWM I/O  on: Mar 26th, 2015, 6:38pm
Started by mmiscool | Post by mmiscool
Spent a bit of time on this today.:D Did some testing.

Made a program with a simple GUI to demonstrate the functions and there usage.

Will be removing old code from previous posts to get rid of confusion and duplication.


BTW. Thank you Chris for the code in AD.Talk.To.Device$()
It has worked flawlessly for me so far.

Some thing in the function AD.Talk.To.Device$() to prevent it from hanging and returning an error if no response is receive from the arduino in a time period of some thing like 10 seconds could be added to make it more resilient.



There is still a need for a more advanced library.
For now there is some code on the street that can be used and worked with for simple I/O operations to control servos and control Christmas lights, ect.

Suggest locking this thread and starting afresh in a new thread to plan out the creation of such a sophisticated library.

LB Code
Code:
 dim  pins$(100)


 'Populate pin list
 for x = 0 to 13
    pins$(x) = str$(x)
 next x


    nomainwin
    WindowWidth = 360
    WindowHeight = 445
    UpperLeftX=int((DisplayWidth-WindowWidth)/2)
    UpperLeftY=int((DisplayHeight-WindowHeight)/2)

    listbox #main.PinSelector, pins$(, [listbox1DoubleClick],   10,  82, 130, 320
    statictext #main.statictext2, "Pin Selector",  10,  62, 130,  20

    textbox #main.ValToSend, 165,  32, 170,  25
    statictext #main.statictext4, "Value To Send", 165,  12, 170,  20
    statictext #main.statictext5, "Return Value", 165,  62, 175,  20
    textbox #main.ReturnValue, 165,  82, 170,  25
    button #main.button7,"Set Pin High/Low Status",[Set.Pin], UL, 165, 117, 170,  25
    button #main.button8,"Get Pin High/Low Status",[Get.Pin], UL, 165, 152, 170,  25
    button #main.button9,"PWM Output (Servos)",[PWM.Out], UL, 165, 187, 170,  25
    button #main.button10,"PWM Input",[PWM.In], UL, 165, 222, 170,  25
    statictext #main.statictext11, "Com Port Number",  10,  12, 145,  20
    textbox #main.ComPortNo,  10,  32, 130,  25

    open "LB Ultra Simple Arduino Demo" for dialog as #main
    print #main, "trapclose [quit.main]"
    wait




[Set.Pin]
    gosub [Get.The.Selctions.And.Textboxes.From.Main.Win]
    return.value = AD.Set(Com.port.Selection, Pin.Selection, Val.To.Send)
    print #main.ReturnValue, return.value
    wait


[Get.Pin]
    gosub [Get.The.Selctions.And.Textboxes.From.Main.Win]
    return.value = AD.Get(Com.port.Selection, Pin.Selection)
    print #main.ReturnValue, return.value
    wait




[PWM.Out]
    gosub [Get.The.Selctions.And.Textboxes.From.Main.Win]
    return.value = AD.PWM.Out(Com.port.Selection, Pin.Selection, Val.To.Send)
    print #main.ReturnValue, return.value
    wait



[PWM.In]
    gosub [Get.The.Selctions.And.Textboxes.From.Main.Win]
    return.value = AD.PWM.In(Com.port.Selection, Pin.Selection)
    print #main.ReturnValue, return.value
    wait



[quit.main]
    close #main
    end





[Get.The.Selctions.And.Textboxes.From.Main.Win]
    print #main.ValToSend, "!contents? Val.To.Send";
    print #main.ComPortNo, "!contents? Com.port.Selection";
    print #main.PinSelector, "selection? Pin.Selection"
    return








'Begin Arduino Code here -------------------------------------------------------
'These functions can be added to any program to provide arduini power input and output
'Descriptions for functions are in there comments


function AD.Set(com.port, PinNo, value)
'Set an Arduino pin high or low,
'Will return 1 one if successful, 0 if not
     AD.Set = val(AD.talk.to.device$(com.port,"set ";PinNo;" ";value))
end function


function AD.Get(com.port, PinNo)
'Will return the current state of the input pin
'1 for high, 0 for low
     AD.Get = val(AD.talk.to.device$(com.port,"get ";PinNo))
end function


function AD.PWM.Out(com.port, PinNo, value)
'Set the PWM output on the select pin to the value
'Will return a 1 for success and 0 for failure.
     AD.PWM.Out = val(AD.talk.to.device$(com.port,"pwm.out ";PinNo;" ";value))
end function


function AD.PWM.In(com.port, PinNo)
'Get the PWM input from the pin
'Will return a value of 0 to 1023
    AD.PWM.In = val(AD.talk.to.device$(com.port,"pwm.in ";PinNo))
end function












Function AD.talk.to.device$(port,msg$)
'Send a Message to the arduino and return the result sent back by the device
    if msg$ <> "" then
        'Open the com port
        open "COM" ; port ; ":9600,n,8,1" for random as #ArduinoCOMPort

        'Send message to device
        print #ArduinoCOMPort, msg$

        'Wait until there is a carriage return
        while foundLF = 0
            while lof(#ArduinoCOMPort) > 0
                temp$ = input$(#ArduinoCOMPort, 1)
                buffer$ = buffer$ + temp$

                if temp$ = chr$(13) then
                    foundLF = 1
                    exit while
                end if
            wend
        wend

        'Place the returned text in to AD.talk.to.device$
        AD.talk.to.device$ = buffer$
        close #ArduinoCOMPort
    else
        Notice "Improper Message Received, Must contain a command"
    end if
End function
 



Arduino Code
Code:

// Buffer to store incoming commands from serial port
String inData;

void setup() {
    Serial.begin(9600);
    Serial.println("Serial conection started, waiting for instructions...");
}

void loop() {
    while (Serial.available() > 0)
    {
        char recieved = Serial.read();
        inData += recieved; 

        // Process message when new line character is recieved
        if (recieved == '\n')
        {
	    String Param0 = getValue(inData, ' ', 0);
	    String Param1 = getValue(inData, ' ', 1);
	    String Param2 = getValue(inData, ' ', 2);
	    String Param3 = getValue(inData, ' ', 3);
	    String Param4 = getValue(inData, ' ', 4);
	    String Param5 = getValue(inData, ' ', 5);
            
            inData = "";

            int valParam0 = Param0.toInt();
            int valParam1 = Param1.toInt();
            int valParam2 = Param2.toInt();
            int valParam3 = Param3.toInt();
            int valParam4 = Param4.toInt();
            int valParam5 = Param5.toInt();
            
            
            //Serial.print(valParam0);
            //Serial.print(valParam1);
            //Serial.print(valParam2);
            //Serial.print(valParam3);
            //Serial.print(valParam4);
            //Serial.print(valParam5);
            
            
            
            
            if ( Param0 == "get")
              {
              pinMode(valParam1, INPUT);
              Serial.println(digitalRead(valParam1));
             
          
              }      

            if ( Param0 == "set")
              {
              pinMode(valParam1, OUTPUT);
              digitalWrite(valParam1, valParam2);
              Serial.println("1");
            
          
              }


            if ( Param0 == "pwm.out")
              {
              analogWrite(valParam1, valParam2);
              Serial.println("1");
          
              }
              
              
              
            if ( Param0 == "pwm.in")
              {
              Serial.println(analogRead(valParam1));
              }              

        }
    }
}




String getValue(String data, char separator, int index)
{
 int found = 0;
  int strIndex[] = {
0, -1  };
  int maxIndex = data.length()-1;
  for(int i=0; i<=maxIndex && found<=index; i++){
  if(data.charAt(i)==separator || i==maxIndex){
  found++;
  strIndex[0] = strIndex[1]+1;
  strIndex[1] = (i == maxIndex) ? i+1 : i;
  }
 }
  return found>index ? data.substring(strIndex[0], strIndex[1]) : "";
}  

 
  Reply Quote Notify of replies

 4   Hardware Interface Coding / Re: Arduino library for LB for pin I/O and PWM I/O  on: Mar 26th, 2015, 4:00pm
Started by mmiscool | Post by mmiscool
setting a pin as input or output is done on the arduino side before the pin is set or queried for status.

Look at the arduino code above.

In this way it becomes transparent to the user. No need to define things ahead of time. Just start telling the pins what to do.


Also the current function above for sending a message to the arduino and return the result is done in such a way that you specify the com port each time.



Code:
AD.talk.to.device$(com.port.no, comand.to.give$) 


 
  Reply Quote Notify of replies

 5   Liberty BASIC Code / Re: Variable Number Of Rows Of Texboxes  on: Mar 26th, 2015, 3:21pm
Started by RNBW | Post by RNBW
Thank you. The code you've provided does the job and I can carry on from there.
I am working with my original coding (that I thought was a bit clumsy) in parallel. There are similarities between the codings in that they both require all the textboxes and statictext typing out, but I'm already there with that, so it's no hardship.
I'll continue with them both and finally decide which way to go.
Thanks again, I'm learning a lot as I work through it.

Ray
 
  Reply Quote Notify of replies

 6   Liberty BASIC Code / Re: Variable Number Of Rows Of Texboxes  on: Mar 26th, 2015, 3:19pm
Started by RNBW | Post by tsh73
BTW, using LOCATE, code from Reply #11 could be re-written without "10+(2-1)*30" stuff.
Here textboxes are created on same line - then LOCATE'd to right places.

Code:
'VARIABLE NUMBERS OF TEXT BOXES
'Code modified from Stefan Pendl code by RNBW
'introducing a third column of textboxes.

NOMAINWIN

TEXTBOX #m.tb11, 10, 10, 75, 25
TEXTBOX #m.tb12, 120, 10, 100, 25
TEXTBOX #m.tb13, 230, 10, 35, 25

TEXTBOX #m.tb21, 10, 10, 75, 25
TEXTBOX #m.tb22, 120, 10, 100, 25
TEXTBOX #m.tb23, 230, 10, 35, 25

TEXTBOX #m.tb31, 10, 10, 75, 25
TEXTBOX #m.tb32, 120, 10, 100, 25
TEXTBOX #m.tb33, 230, 10, 35, 25

TEXTBOX #m.tb41, 10, 10, 75, 25
TEXTBOX #m.tb42, 120, 10, 100, 25
TEXTBOX #m.tb43, 230, 10, 35, 25

STATICTEXT #m.txt, "Enter number of rows (1 to 4) and hit update", 10, 140, 200, 30
TEXTBOX #m.tbn, 10, 170, 50, 25

BUTTON #m.ud, "update", [update], ul, 70, 170, 100, 25

OPEN "Text box test" FOR WINDOW AS #m
#m "trapclose [quit]"
'set editors to right places

for row = 1 to 4
    handle$ = "#m.tb"; row; 1 
    #handle$ "!locate "; 10;" ";10+(row-1)*30;" ";75;" ";25
    handle$ = "#m.tb"; row; 2 
    #handle$ "!locate "; 120;" ";10+(row-1)*30;" ";100;" ";25
    handle$ = "#m.tb"; row; 3 
    #handle$ "!locate "; 230;" ";10+(row-1)*30;" ";35;" ";25
next
#m "refresh"

#m.tbn "!setfocus"

wait

[update]
#m.tbn "!contents? number"

number = int(number)
cols=3

for row = 1 to 4
    for col = 1 to cols
        handle$ = "#m.tb"; row; col
        if  row <= number then
            #handle$ "!show"
        else
            #handle$ "!hide"
        end if
    next
next

#m.tbn "!setfocus"
wait

[quit]
close #m
end  

 
  Reply Quote Notify of replies

 7   Liberty BASIC Code / Re: Variable Number Of Rows Of Texboxes  on: Mar 26th, 2015, 3:02pm
Started by RNBW | Post by tsh73
Quote:
I'd be grateful for any solutions.

Here are 4 solutions (there may be more):
1) stop worrying, continue coding.
Really, some empty space on a form not worst thing that could happen.
2) rearrange controls so grid is last (bottom-wise) thing on a form. I hope there is a way to resize window to hide that extra space then
3) put a grid on separate window. Obviously you could control it's size then
4) use LOCATE to move controls that supposed to be under the grid
Code:
'VARIABLE NUMBERS OF TEXT BOXES
'Code modified from Stefan Pendl code by RNBW
'introducing a third column of textboxes.

NOMAINWIN
[WindowSetup]
 NOMAINWIN
 WindowWidth = 1032 : WindowHeight = 650
 UpperLeftX = INT((DisplayWidth-WindowWidth)/2)
 UpperLeftY = INT((DisplayHeight-WindowHeight)/2)
' ----------------------------------------------------

[ControlSetup]
vpos = 10: sp = 25: TopOfTable = vpos+sp*9
STATICTEXT #m.txt, "Enter number of rows (1 to 4) and hit update", 10, vpos+sp*3, 200, 25
STYLEBITS #m.tbn, 0, _WS_BORDER,0,0
TEXTBOX #m.tbn, 10, vpos+sp*4, 50, 25

BUTTON #m.b1, "UPDATE", [update], UL, 70, vpos+sp*4, 100, 25

BUTTON #m.b2, "CALCULATE TABLE", [calcTable], UL, 200, vpos+sp*4, 150, 25

MENU #m, "&File" , "E&xit", [quit]
'Row 1
STYLEBITS #m.top11, 0, _WS_BORDER,0,0
TextboxColor$ = "cyan"
TEXTBOX #m.top11, 10, (TopOfTable-25)+(1-1)*sp, 75, 25
STYLEBITS #m.top12, 0, _WS_BORDER,0,0
TEXTBOX #m.top12, 85, (TopOfTable-25)+(1-1)*sp, 300, 25
STYLEBITS #m.top13, 0, _WS_BORDER,0,0
TEXTBOX #m.top13, 385, (TopOfTable-25)+(1-1)*sp, 75, 25

'Row2
STYLEBITS #m.tb11, 0, _WS_BORDER,0,0
TextboxColor$ = "cyan"
TEXTBOX #m.tb11, 10, TopOfTable+(1-1)*sp, 75, 25
STYLEBITS #m.tb12, 0, _WS_BORDER,0,0
TextboxColor$ = "White"
TEXTBOX #m.tb12, 85, TopOfTable+(1-1)*sp, 300, 25
STYLEBITS #m.tb13, 0, _WS_BORDER,0,0
TEXTBOX #m.tb13, 385, TopOfTable+(1-1)*sp, 75, 25

'Row 3
STYLEBITS #m.tb21, 0, _WS_BORDER,0,0
TextboxColor$ = "cyan"
TEXTBOX #m.tb21, 10, TopOfTable+(2-1)*sp, 75, 25
STYLEBITS #m.tb22, 0, _WS_BORDER,0,0
TextboxColor$ = "White"
TEXTBOX #m.tb22, 85, TopOfTable+(2-1)*sp, 300, 25
STYLEBITS #m.tb23, 0, _WS_BORDER,0,0
TEXTBOX #m.tb23, 385, TopOfTable+(2-1)*sp, 75, 25

'Row4
STYLEBITS #m.tb31, 0, _WS_BORDER,0,0
TextboxColor$ = "cyan"
TEXTBOX #m.tb31, 10, TopOfTable+(3-1)*sp, 75, 25
STYLEBITS #m.tb32, 0, _WS_BORDER,0,0
TextboxColor$ = "White"
TEXTBOX #m.tb32, 85, TopOfTable+(3-1)*sp, 300, 25
STYLEBITS #m.tb33, 0, _WS_BORDER,0,0
TEXTBOX #m.tb33, 385, TopOfTable+(3-1)*sp, 75, 25

posBelow=TopOfTable+(4-1)*sp+15
BUTTON #m.btn1, "This", returnVar, UL, 10, posBelow' {, width, height}
STATICTEXT #m.lbl1, "stuff wil be moved", 60, posBelow, 50, 25
TEXTBOX #m.txt1, 130, posBelow, 175, 25

'Open a window
OPEN "Text box test" FOR WINDOW AS #m
#m "trapclose [quit]"

#m.tbn "!setfocus"
#m.txt1 "down with table size"
wait

[update]
#m.tbn "!contents? number"

number = int(number)
cols=3

for row = 1 to 3
 for col = 1 to cols
 handle$ = "#m.tb"; row; col
 if row <= number then
 #handle$ "!show"
 else
 #handle$ "!hide"
 end if
 next
next

'---------------------
'move controls below the table
num=number
if number<4 then num=number+1   'actually something is wrong with your "number" here
posBelow=TopOfTable+(num-1)*sp+15
#m.btn1, "!locate "; 10;" ";posBelow;" ";50;" ";25
#m.lbl1, "!locate "; 60;" ";posBelow;" ";50;" ";25
#m.txt1, "!locate ";130;" ";posBelow;" ";175;" ";25
#m "refresh"
'---------------------

#m.tbn "!setfocus"

wait

[calcTable]
'Put calculation of table code here
GOTO [update]

[quit]
close #m
end 


I'd really go for (1).
 
  Reply Quote Notify of replies

 8   Liberty BASIC Code / Re: "timer 0" not working  on: Mar 26th, 2015, 2:46pm
Started by hooshnik | Post by hooshnik
You know one thing that threw me off was the timer was being set to 0 when an exit button was pressed, and it had to be pressed in order to continue the program (it's a product activation window). So the program was surreptitiously being boggled by my paste button which didn't set timer to 0 even though it comes before the exit button. I can't figure out why. The program pretends to work until a scan statement.
 
  Reply Quote Notify of replies

 9   Liberty BASIC Code / Re: Variable Number Of Rows Of Texboxes  on: Mar 26th, 2015, 1:28pm
Started by RNBW | Post by RNBW
on Mar 23rd, 2015, 4:40pm, Stefan Pendl wrote:
So we speak of a limited number of controls, that we only have to show and hide or enable and disable.
This doesn't need a spreadsheet or grid control, so you could adapt my example.

The text in a static text control can be changed after it has been created, so you have plenty of options available to mimic a spreadsheet grid.

----------------------------------------------------------------
The problem that I am finding with the "Hide" and "Show" solution, is that where texboxes are hidden, I can't find a method by which a later control doesn't leave a gap. In the worst case there are 8 rows and a following control's position has to be calculated on that. If the number of rows is reduced to say 2, then a 6 row gap occurs.

I've tried all sorts of solutions but I just can't get over this problem.

Has anybody any ideas? My code (without any following controls) is shown below:

'VARIABLE NUMBERS OF TEXT BOXES
'Code modified from Stefan Pendl code by RNBW
'introducing a third column of textboxes.

NOMAINWIN
[WindowSetup]
NOMAINWIN
WindowWidth = 1032 : WindowHeight = 650
UpperLeftX = INT((DisplayWidth-WindowWidth)/2)
UpperLeftY = INT((DisplayHeight-WindowHeight)/2)
' ----------------------------------------------------

[ControlSetup]
vpos = 10: sp = 25: TopOfTable = vpos+sp*9
STATICTEXT #m.txt, "Enter number of rows (1 to 4) and hit update", 10, vpos+sp*3, 200, 25
STYLEBITS #m.tbn, 0, _WS_BORDER,0,0
TEXTBOX #m.tbn, 10, vpos+sp*4, 50, 25

BUTTON #m.b1, "UPDATE", [update], UL, 70, vpos+sp*4, 100, 25

BUTTON #m.b2, "CALCULATE TABLE", [calcTable], UL, 200, vpos+sp*4, 150, 25

MENU #m, "&File" , "E&xit", [quit]
'Row 1
STYLEBITS #m.top11, 0, _WS_BORDER,0,0
TextboxColor$ = "cyan"
TEXTBOX #m.top11, 10, (TopOfTable-25)+(1-1)*sp, 75, 25
STYLEBITS #m.top12, 0, _WS_BORDER,0,0
TEXTBOX #m.top12, 85, (TopOfTable-25)+(1-1)*sp, 300, 25
STYLEBITS #m.top13, 0, _WS_BORDER,0,0
TEXTBOX #m.top13, 385, (TopOfTable-25)+(1-1)*sp, 75, 25

'Row2
STYLEBITS #m.tb11, 0, _WS_BORDER,0,0
TextboxColor$ = "cyan"
TEXTBOX #m.tb11, 10, TopOfTable+(1-1)*sp, 75, 25
STYLEBITS #m.tb12, 0, _WS_BORDER,0,0
TextboxColor$ = "White"
TEXTBOX #m.tb12, 85, TopOfTable+(1-1)*sp, 300, 25
STYLEBITS #m.tb13, 0, _WS_BORDER,0,0
TEXTBOX #m.tb13, 385, TopOfTable+(1-1)*sp, 75, 25

'Row 3
STYLEBITS #m.tb21, 0, _WS_BORDER,0,0
TextboxColor$ = "cyan"
TEXTBOX #m.tb21, 10, TopOfTable+(2-1)*sp, 75, 25
STYLEBITS #m.tb22, 0, _WS_BORDER,0,0
TextboxColor$ = "White"
TEXTBOX #m.tb22, 85, TopOfTable+(2-1)*sp, 300, 25
STYLEBITS #m.tb23, 0, _WS_BORDER,0,0
TEXTBOX #m.tb23, 385, TopOfTable+(2-1)*sp, 75, 25

'Row4
STYLEBITS #m.tb31, 0, _WS_BORDER,0,0
TextboxColor$ = "cyan"
TEXTBOX #m.tb31, 10, TopOfTable+(3-1)*sp, 75, 25
STYLEBITS #m.tb32, 0, _WS_BORDER,0,0
TextboxColor$ = "White"
TEXTBOX #m.tb32, 85, TopOfTable+(3-1)*sp, 300, 25
STYLEBITS #m.tb33, 0, _WS_BORDER,0,0
TEXTBOX #m.tb33, 385, TopOfTable+(3-1)*sp, 75, 25

'Open a window
OPEN "Text box test" FOR WINDOW AS #m
#m "trapclose [quit]"

#m.tbn "!setfocus"
wait

[update]
#m.tbn "!contents? number"

number = int(number)
cols=3

for row = 1 to 3
for col = 1 to cols
handle$ = "#m.tb"; row; col
if row <= number then
#handle$ "!show"
else
#handle$ "!hide"
end if
next
next

#m.tbn "!setfocus"

wait

[calcTable]
'Put calculation of table code here
GOTO [update]

[quit]
close #m
end


I'd be grateful for any solutions.

Ray
 
  Reply Quote Notify of replies

 10   Hardware Interface Coding / Re: Arduino library for LB for pin I/O and PWM I/O  on: Mar 26th, 2015, 12:06pm
Started by mmiscool | Post by Brandon Parker
on Mar 26th, 2015, 06:14am, mmiscool wrote:
The need for a more complex and structure implication of an arduni library is not negated by having a simple basic one.

Many people still want to program in a procedural way to preserve the qbasic-nes of the LB language and providing direct feed back from a function that has a single use and has direct access to pin level i/o is a big step towards making it easier for entry level people to get in on more sophisticated functionality.

Hense the desire for a set of functions that will just send data to and receive data back without having to implement complex loops and data parsing.




Simple ability to wire up to an arduno board and not have to understand C or attempt to off load too much to board is key.



I do not disagree with what you are saying, but the definition of a Library is exactly what you are trying to avoid. A Library can be simple if it doesn't do much, but more often than not it is a highly complex piece of work that is used for abstraction. When you can call a simple function and that function acts out 50 highly complex lines of code without the user having to understand them then you are seeing exactly what libraries are meant to do.

@Chris,
You are exactly correct; we need to describe exactly what WE, as a group, would like to achieve and act on sections of that list at a time. We can say "we want some simple functions for interfacing LB-Arduino", but we should describe in detail what each one should do and how we are to go about doing that. Style of coding is also important; you don't necessarily want 8 different styles of coding in the same library; keeping things organised and looking similar is always a good way to help people understand the overall code.

Making the library a bit more complex could also allow for it's use with multiple Arduino's at the same time

@Carl - How difficult would it be for you to make the Hwnd() function be able to return the actual Windows handle for the COM Port under the #myHandle. Also, using variable handles with COM Ports would be extremely useful as well. I supposed we could go the API route if needed in the future.

Just some thoughts here.....

{:0)

Brandon

 
  Reply Quote Notify of replies


Rules|Home|Help|Search|Recent Posts|Notification



Donate $6.99 for 50,000 Ad-Free Pageviews!

| |

This forum powered for FREE by Conforums ©
Sign up for your own Free Message Board today!
Terms of Service | Privacy Policy | Conforums Support | Parental Controls