RetroBSD

2.11BSD operating system for microcontrollers
It is currently Wed Jul 18, 2018 1:19 am

All times are UTC




Post new topic Reply to topic  [ 7 posts ] 
Author Message
PostPosted: Tue Oct 16, 2012 12:02 am 
User avatar

Joined: Thu Oct 11, 2012 3:21 pm
Posts: 26
Location: USA
I'm confused about the pin configuration in the board makefiles.
In starter-kit/Makefile we find these lines:

# SD/MMC card driver on SPI1
# /CS0 at pin B1
DEFS += -DSD_PORT=SPI1CON -DSD_MHZ=10
DEFS += -DSD_CS0_PORT=TRISB -DSD_CS0_PIN=1

# LEDs at pins D0 (red), D1 (yellow), D2 (green)
DEFS += -DLED_TTY_PORT=TRISD -DLED_TTY_PIN=0
DEFS += -DLED_DISK_PORT=TRISD -DLED_DISK_PIN=1
DEFS += -DLED_KERNEL_PORT=TRISD -DLED_KERNEL_PIN=2

The MCU SPI1 uses the same pin (72) for LED on D0 as SDO1.
Seems either there's a conflict there or I'm missing something.


Top
 Profile  
 
PostPosted: Tue Oct 16, 2012 12:59 am 
Committer
User avatar

Joined: Thu Oct 11, 2012 8:45 am
Posts: 1801
Location: Room 217, Floor 8, Arm 8, Wheel S7, Mars Base Alpha 3
Which chip is on the starter kit? The only reference I can find is to the PIC32MX360F512L, which doesn't have enough RAM to run Retro.

For the '795L chip, yes pin 72 is both SDO1 and D0.

_________________
Why not visit my shop? http://majenko.co.uk/catalog
Universal IDE: http://uecide.org
"I was trying to find out if it was possible to only eat one Jaffa Cake. I had to abandon the experiment because I ran out of Jaffa Cakes".


Top
 Profile  
 
PostPosted: Tue Oct 16, 2012 1:09 am 
User avatar

Joined: Thu Oct 11, 2012 3:21 pm
Posts: 26
Location: USA
The one to which I refer is the USB Starter Kit 2.
It has the 795F512L on it.

My point was, you wouldn't put the LED on a pin you are using for the SD card. So the config in this Makefile must be for a different starter kit?

I'm both trying to understand the lay of the land, as well as make good selections for where I wire my LEDs, etc.


Top
 Profile  
 
PostPosted: Tue Oct 16, 2012 1:10 am 
Committer

Joined: Thu Nov 08, 2012 3:55 am
Posts: 177
That is a conflict. However, it might actually work that way since the processor will not be changing the tty led while it is using d0 to communicate with the sd card. Hopefully someone with retrobsd running on a starter-kit will comment.


Top
 Profile  
 
PostPosted: Tue Oct 16, 2012 1:58 am 
Contributor

Joined: Mon Nov 12, 2012 1:34 pm
Posts: 1091
Hi,

I have an ethernet starter kit. I haven't tried to run RetroBSD on it
(yet?) since it has really strange connectors :(.

I do run RetroBSD on a data collection kludge and a MAX32 with an apparently similar enough pinout.

Most folks seem to use the usb port to get started with MicroChip's "stock" software and use that to load the chip with firmware. This requires a usb bootloader.

I use my own bootloader/debugger that runs serial 4800 baud. Works reliably but isn't as fast. I load software VIA J-TAG with a customized version of xc3sprog running on an old PC with a parallel port. Which is VERY slow :(.

The ethernet starter kit has 2 PIC32s on it! One is used for software load and debug VIA the J-TAG port and a few other lines on the target PIC32. All this (supposedly and probably) "just works" if you use the MicroChip software.

You might consider buying or building a MAX32 work alike. Then you won't have to start by debugging stuff. And that board is the default and seems to have the most folks using it (IMHO).

I just download the new version and compile, load and run it. Generally this just works.

HTH

Wiz


Top
 Profile  
 
PostPosted: Tue Oct 16, 2012 2:16 am 
User avatar

Joined: Thu Oct 11, 2012 3:21 pm
Posts: 26
Location: USA
Wiz, I'm using homemade bareboard hardware. And I do have the (a) bootloader working.

Hardware is mentioned here: http://retrobsd.org/topic/bareboard-prototype/
-Bill


Top
 Profile  
 
PostPosted: Tue Oct 16, 2012 2:42 am 
Committer
User avatar

Joined: Wed Oct 10, 2012 11:01 pm
Posts: 1079
Location: Sunnyvale, CA
Yes, it's a conflict. Pin D0 is used as SDO1, so it cannot work as tty LED.
Need to fix a Makefile, thanks.
--Serge

_________________
--Serge


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 7 posts ] 

All times are UTC


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
cron




Powered by phpBB® Forum Software © phpBB Group

BSD Daemon used with permission