log in | register | forums
Show:
Go:
Forums
Username:

Password:

User accounts
Register new account
Forgot password
Forum stats
List of members
Search the forums

Advanced search
Recent discussions
- Elsear brings super-fast Networking to Risc PC/A7000/A7000+ (News:)
- Latest hardware upgrade from RISCOSbits (News:)
- RISC OS London Show Report 2024 (News:1)
- Announcing the TIB 2024 Advent Calendar (News:1)
- Code GCC produces that makes you cry #12684 (Prog:39)
- RISCOSbits releases a new laptop solution (News:)
- Rougol November 2024 meeting on monday (News:)
- Drag'n'Drop 14i1 edition reviewed (News:)
- WROCC November 2024 talk o...ay - Andrew Rawnsley (ROD) (News:2)
- October 2024 News Summary (News:3)
Latest postings RSS Feeds
RSS 2.0 | 1.0 | 0.9
Atom 0.3
Misc RDF | CDF
 
View on Mastodon
@www.iconbar.com@rss-parrot.net
Site Search
 
Article archives
Acorn Arcade forums: Programming: User/Analogue port
 
  User/Analogue port
  mookie (14:58 24/12/2006)
  VincceH (16:11 24/12/2006)
    mookie (16:27 24/12/2006)
 
John Lindley Message #96232, posted by mookie at 14:58, 24/12/2006
Member
Posts: 6
Finally, after a long break there are Acorn computers in my house again, thanks to a wonderful job lot purchase. The reason for the return is to use them in a computer control project, and because I still haven't found a windows/linux text editor I really like.

The question I have is this, I was lucky enough for one of the machines to include a user/analogue port and I'm looking to use this as the basis of the control. Possibly combined with the parallel port, but I digress. Accessing the cardis straightforward under BASIC but I was hoping to be able to use C as the osoftware could end up as something rather large. Do you know of any wrapper or interface to access the ADVAL command from C?

Sorry for the ramble, it just feels nice to be talking about acorns agains.

John Lindley
  ^[ Log in to reply ]
 
VinceH Message #96239, posted by VincceH at 16:11, 24/12/2006, in reply to message #96232
VincceH
Lowering the tone since the dawn of time

Posts: 1600
You 'simply' need to understand how to access the user/analogue port via SWI calls, or via a library which provides a nice wrapper for them. I don't know for certain, but I'd hazzard guess that it will either be via OS_Word or OS_Byte.
  ^[ Log in to reply ]
 
John Lindley Message #96243, posted by mookie at 16:27, 24/12/2006, in reply to message #96239
Member
Posts: 6
I was happy with the SWI for the user port, it's reading the analogue side that seems trickier as it doesn't use an OS_BYTE call but a call to ADVAL which is a little more specific and as far as I can see BASIC specific.
  ^[ Log in to reply ]
 

Acorn Arcade forums: Programming: User/Analogue port