Did you get any previous warnings or written up?  How late are we talking about, 5-10 minutes every so often or like everyday 2-3 min late?
I was late today 45 min on the job.  I was on the floor 2 min early but had logon issues and couldn't begin taking calls until 45min earlier.  
On a average week I'm late once or twice for about 2-3 min.  Even if I can leave home for work early I have the bad habit of waiting til the last minute.  There's days when I stay over 5-30min past my required scheduled time.  They know and it evens out itself.  Most of last quarter I often left work 1-2 min early.  As long as I'm within the expected service range I'm ok.
This quarter I had 7 sick days.
Last quarter I had 8 sick days.
The quarter before that I had 6 sick days.
All sick days are fully paid as regular working days. 
All legitimate reasons with doctor's support.  There's a letter on my file requiring doctor's note each time I call in sick.  I've been thru several supervisors and all are aware and very understanding of my issues.  
Even with all the sick days and I still pulled my numbers they asked for and even exceeded it, so they're happy and I still have a job.  But I'm sure if my sales sucked my job would be on the line.  
I've been fired from my 1st job.  It's not as big a deal as you may come to think.  Keep yourself busy, chalk it up to a learning experience and march forward!  
