This Forum is Dedicated For all The Object Oriented PIC Lovers .......... The concept behind OOPic is straight forward. Use preprogrammed multitasking Objects from a library of highly optimized Objects to do all the work of interacting with the hardware. Then write small scripts in Basic, C, or Java syntax styles to control the Objects. During operation, the Objects run continuously and simultaneously in the background while the scripts run in the foreground telling the objects what to do.

Saturday, March 1, 2008

[oopic] Re: SCP accessing variables in RAM getting garbage

Thanks Ian,

That certainly works for variable, but it breaks down with objects. I
expanded my sample test and these are the results:

---

OOPic Code:

Dim firstByte As Byte

Dim secondByte As Byte

Dim thirdByte As Byte

Dim firstWord As Word

Dim secondWord As Word

Dim firstObj As oByte

Dim secondObj As oByte

Dim thirdObj As oMathO

Sub Main()

..firstByte = 15 '0F hex

..secondByte = 171 'AB hex

..thirdByte = 205 'CD hex

..firstWord = 4660 '1234 hex

..secondWord = 43981 'ABCD hex

..firstObj = 15

..secondObj = 1

..thirdObj.Input1.Link(firstObj)

..thirdObj.Input2.Link(secondObj)

..thirdObj.Mode = cvAdd

..thirdObj.Operate = cvOn

End Sub

---

Mapping in information box in the OOPic interface:

firstByte = Bank1, AreaV, Bank in sub address: 2

secondByte = Bank1, AreaV, Bank in sub address: 2

thirdByte = Bank1, AreaV, Bank in sub address: 2

firstObj = Bank0, AreaI, Bank in sub address: 0

secondObj = Bank0, AreaI, Bank in sub address: 0

thirdObj = Bank0, AreaA, Bank in sub address: 0

Note that we would expect that firstObj and secondObj would use bank 1
in the sub address to be consistant with the "areas map to
banks" theory, but it isn't the same in practice.

---

Lines from the Omp file:

V.I-126.....2..oByte.........firstObj

V.I-124.....2..oByte.........secondObj

V.A-41......5..oMathO........thirdObj

---

The conversation:

Send: \0V
Recv: v
Send: U
Send: 0H126J0LM = read value of firstObj
Recv: 15m = expected value
Send: 0H41J0LM = read value of thirdObj
Recv: 16m = expected value

This test would imply that things in Area A, and Area I need a sub
address bank of 0, whereas things in Area V need a sub address bank of
2. I have no idea what Area F is for.

Ian, if you have time would you independently verify these findings. I
need a sanity check.

Thanks,

Dogulas

[Non-text portions of this message have been removed]


Yahoo! Groups Links

<*> To visit your group on the web, go to:

http://groups.yahoo.com/group/oopic/

<*> Your email settings:
Individual Email | Traditional

<*> To change settings online go to:

http://groups.yahoo.com/group/oopic/join

(Yahoo! ID required)

<*> To change settings via email:
mailto:oopic-digest@yahoogroups.com
mailto:oopic-fullfeatured@yahoogroups.com

<*> To unsubscribe from this group, send an email to:
oopic-unsubscribe@yahoogroups.com

<*> Your use of Yahoo! Groups is subject to:

http://docs.yahoo.com/info/terms/

No comments: